CIE: Add "CIE L float"
authorDebarshi Ray <debarshir@gnome.org>
Thu, 9 Nov 2017 06:48:26 +0000 (07:48 +0100)
committerDebarshi Ray <debarshir@gnome.org>
Sat, 11 Nov 2017 20:03:58 +0000 (21:03 +0100)
commitbdcd090c17aebd8ffb964d98cd0984a3fc123a50
tree0e235a76f44ed4124445a8622fa33ee6e5a9a690
parent23def34b96fb69cfe9ca3c8e8cee7c01383779ff
CIE: Add "CIE L float"

Some of these conversions will be leveraged by gegl:shadows-highlights
which needs to go from "Y float" or "YaA float" to "CIE L float".

The conversion from "RGBA float" was added to aid "YaA float" to
"CIE L float" fishes. They go via:
  "YaA float"     to "RaGaBaA float"
  "RaGaBaA float" to "RGBA float"
  "RGBA float"    to "Y float"
  "Y float"       to "CIE L float"

A direct conversion from "YaA float" to "Y float" in simple C is
hindered by the need to check every pixel's alpha value to avoid
dividing by zero. The pipeline stalls make it lose out to the look-up
table and SIMD based RGB conversions to unassociated alpha.

However, we can trivially cut out the third step and still reduce some
memory traffic.

https://bugzilla.gnome.org/show_bug.cgi?id=790111
extensions/CIE.c